package io.renren.common.utils.enums;


/**
 * @program: renren-fast
 * @description:
 * @author: zhangxy
 * @create: 2019-10-10 21:49
 **/
public enum payTypeEnums {
    offline_status("offline","线下支付"),
    recharge_status("failed","failed"),
    selfincome_status("error","error"),
    online_status("online","在线支付");

    private String type;

    private String value;

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    payTypeEnums(String type, String value) {
        this.type = type;
        this.value = value;
    }


    public static String getValueByType(String type){
        payTypeEnums[] enums = values();
        for (payTypeEnums enum1 : enums){
            if (enum1.getType().equals(type)){

                return enum1.getValue();
            }
        }
        return null;
    }

}
